﻿using System;
using System.Collections.Generic;
using System.ServiceModel;
using BluePortal.Framework;
using BluePortal.Medias.Core;

namespace BluePortal.Medias.Services.Soap
{
    [ServiceContract(Namespace = "BluePortal.Medias.Services.Soap")]
    public interface ITagService
    {
    }

    public class TagService : ITagService
    {
        private BCTag service = new BCTag();

        #region IVideoTagService Members

        public IEnumerable<Tag> FindAll()
        {
            return service.FindAll();
        }

        public IEnumerable<Tag> FindAllWithMediaTag()
        {
            return service.FindAllWithMediaTag();
        }

        public IEnumerable<Tag> FindStartWith(string s)
        {
            return service.FindStartWith(s);
        }

        public IEnumerable<Tag> FindByID(Guid vid)
        {
            return service.FindByID(vid);
        }

        public IEnumerable<Tag> FindByMedia(Media media)
        {
            return service.FindByMedia(media);
        }

        public System.Collections.IEnumerable FindAllForTagCloud()
        {
            return service.FindAllForTagCloud();
        }

        public void Add(Media media, Tag t)
        {
            service.Add(media, t);
        }

        public void Add(Media media, string t)
        {
            service.Add(media, t);
        }

        public void Remove(Guid vid, Guid tid)
        {
            service.Remove(vid, tid);
        }

        #endregion
    }
}

